<template>
    <div class="station-top">
        <el-button link @click="handleFront">前台预览</el-button>
    </div>
</template>
<script setup>
import { encrypt } from '@ruifox-cms/utils'
import { useStore } from 'vuex'

const store = useStore()
// 前台预览
const handleFront = () => {
  window.open(`${location.origin}${process.env.BASE_URL}recruitment/user/home?groupId=${encrypt(store.state.base.userInfo.groupId)}`, '_blank')
}
</script>

<style lang="scss" scoped>
.station-top {
  display: flex;
  align-items: center;
  height: 100%;
  .el-button {
    margin: 0 15px;
  }
}
</style>